<template>
  <base-page v-bind="baseInfo">
    <template #searchBar>
      <filter-form
        ref="filterForm"
        :elements="elements"
        @submit="submit"
      />
    </template>
    <template #content>
      <div class="table-box">
        <TableNew
          :loading="tableLoading"
          :data="tableData"
          :columns="tableEl"
          :pagination="pagination"
          @paginationChange="paginationChange"
        >
          <template #action="">
            <el-tooltip class="item" effect="dark" content="查看" placement="top" :open-delay="600">
              <i class="el-icon-tickets action" />
            </el-tooltip>
            <el-tooltip class="item" effect="dark" content="编辑" placement="top" :open-delay="600">
              <i class="el-icon-edit-outline action" />
            </el-tooltip>
            <el-tooltip class="item" effect="dark" content="删除" placement="top" :open-delay="600">
              <i class="el-icon-delete action" />
            </el-tooltip>
          </template>
        </TableNew>
      </div>
    </template>
  </base-page>
</template>

<script>
import baseFilterTable from '@/mixins/baseFilterTable'

export default {
  name: 'EvaluationConfig', // 考核细则配置
  components: {},
  mixins: [baseFilterTable],
  props: {},
  data() {
    return {
      baseInfo: {
        searchBarShow: true
      },
      tableData: [],
      tableEl: [
        {
          title: '占位列1',
          dataIndex: 'columnO',
          width: 140
        },
        {
          title: '占位列2',
          dataIndex: 'columnTw'
        },
        {
          title: '占位列3',
          dataIndex: 'columnTh'
        },
        {
          title: '占位列4',
          dataIndex: 'columnF'
        },
        {
          title: '操作',
          dataIndex: 'action',
          type: 'otherTag',
          align: 'center'
        }
      ],
      elements: [
        {
          label: '输入',
          type: 'input',
          key: 'input',
          value: ''
        },
        {
          label: '时间',
          type: 'date-picker',
          mode: 'daterange',
          key: 'date',
          value: ''
        },
        {
          label: '下拉',
          type: 'select',
          options: [],
          key: 'select',
          value: ''
        }
      ]
    }
  },
  created() {},
  mounted() {},
  methods: {
    async getData(val) {
    }
  }
}
</script>

<style lang="less" scoped>
.table-box{
  height: 100%;
  display: flex;
  flex-direction: column;
}
</style>
